# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=python2-unicodecsv
_pkgname=unicodecsv
pkgver=0.14.1
pkgrel=5
pkgdesc="Python2's stdlib csv module is nice, but it doesn't support unicode. This module is a drop-in replacement which *does*."
url='https://pypi.org/project/unicodecsv/#files'
arch=('any')
license=('BSD')
depends=('python2')
makedepends=('python2-setuptools')
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$_pkgname-$pkgver.tar.gz")
sha512sums=('fdd7696c4ccfd478dbf1ff846714b7bab4711ca294fb212ae173b66becd2f9220cbcf69afb8e00162312373d9e59a6336bd7be2f5c270ac0dee359a830290bd9')

build() {
  cd "$_pkgname-$pkgver"

  python2 setup.py build
}

package() {
  cd "$_pkgname-$pkgver"

  python2 setup.py install --root="$pkgdir" --prefix=/usr -O1 --skip-build
}

